package attend.action.common;

import java.sql.SQLException;
import java.util.HashMap;
import java.util.List;

import attend.UserContainer.User;
import attend.com.Session;
import attend.dao.CommonAttendDAO;
import exception.BaseException;

/**
 * 사업그룹코드/명 조회
 * @author ych
 * @since 2009-01-09
 */
public class RetrieveGroupByUseYAction extends Session {
	
	private List<HashMap<String,String>> 	list_upper_dept 	= 	null;	//select list
	
	private CommonAttendDAO 				commonDao 			= 	null;

	private User user;
	
	public String execute() throws BaseException, SQLException {
		
		commonDao 			= 	new CommonAttendDAO();
		
		commonDao.retrieveGroupByUseY();
		
		list_upper_dept 	= 	commonDao.getList();
		
		return "success";
	}
	
	/****************************GETTER / SETTER******************************/
	public List<HashMap<String, String>> getList_upper_dept() {
		return list_upper_dept;
	}

	public void setList_upper_dept (List<HashMap<String, String>> list_upper_dept) {
		this.list_upper_dept = list_upper_dept;
	}
	
	@Override
	public void setUser(User user) {
		this.user = user;
		
	}

	public User getUser() {
		return user;
	}
	/****************************GETTER / SETTER******************************/
}
